package com.study.spring.cloud.config.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @ClassName: TestController
 * @Description:
 * @author: limingxing
 * @Date: 2020-07-10 16:14
 */
@RefreshScope
@RestController
public class TestController {

    @Value("${profile}")
    private String profile;

    @RequestMapping("/profile")
    public String from() {
        return this.profile;
    }

}